In [1]:
push!(LOAD_PATH,"../src")
using Laplacians

In [2]:
include("../src/isotonicIPM.jl")


Out[2]:
notFeasible (generic function with 1 method)

In [3]:
n = 100;
A = grid2(10,10)
A = triu(A);
v = randn(n)+collect(1:n)/2;
isoTestValues = collect(1:n);
newOrder = randperm(n)
permMat = (speye(n))[1:n,newOrder];
A = permMat*A*permMat';
v = permMat*v;
@time (x,acc,itercount) = isotonicIPM(A,v);


  2.960131 seconds (2.79 M allocations: 136.799 MB, 1.88% gc time)

In [4]:
n = 10000;
A = grid2(100,100)
A = triu(A);
v = randn(n)+collect(1:n)/2;
isoTestValues = collect(1:n);
newOrder = randperm(n)
permMat = (speye(n))[1:n,newOrder];
A = permMat*A*permMat';
v = permMat*v;
@time (x,acc,itercount) = isotonicIPM(A,v);


 10.038785 seconds (11.09 M allocations: 4.151 GB, 6.46% gc time)

In [5]:
(acc,itercount)


Out[5]:
(0.006369223115374467,122)

In [ ]:
H -> H^2

In [ ]:
n = 40000;
A = grid2(200,200)
A = triu(A);
v = randn(n)+collect(1:n)/2;
isoTestValues = collect(1:n);
newOrder = randperm(n)
permMat = (speye(n))[1:n,newOrder];
A = permMat*A*permMat';
v = permMat*v;
(x,acc,itercount) = isotonicIPM(A,v);

In [ ]:
(acc,itercount)

In [ ]:
n = 1000;
A = randRegular(n,3)
A = triu(A);
v = randn(n)+collect(1:n)/2;
isoTestValues = collect(1:n);
newOrder = randperm(n)
permMat = (speye(n))[1:n,newOrder];
A = permMat*A*permMat';
v = permMat*v;
(x,acc,itercount) = isotonicIPM(A,v,0.01);

In [ ]:
(acc,itercount)

In [ ]:
n = 3000;
A = randRegular(n,3)
A = triu(A);
v = randn(n)+collect(1:n)/2;
isoTestValues = collect(1:n);
newOrder = randperm(n)
permMat = (speye(n))[1:n,newOrder];
A = permMat*A*permMat';
v = permMat*v;
(x,acc,itercount) = isotonicIPM(A,v);

In [ ]:
(acc,itercount)

Now, let's try using the relative error option.


In [ ]:
n = 10000;
A = grid2(100,100)
A = triu(A);
v = randn(n)+collect(1:n)/2;
isoTestValues = collect(1:n);
newOrder = randperm(n)
permMat = (speye(n))[1:n,newOrder];
A = permMat*A*permMat';
v = permMat*v;
(x,acc,itercount) = isotonicIPMrelEps(A,v,0.01);

In [ ]:
(acc,itercount)

In [ ]:


In [ ]: